---
title: PDF pass-through or PDF/A upgrade
summary: Return a PDF source unchanged, or upgrade it to PDF/A conformance.
status: draft
owner: SAIF Doc Gen
last_reviewed: 2026-09-17
library: PdfAPI.SyncFusionCore
reference_type: package
operation_id: OP-SFC-009
trigger: Called by ConverterFactory for the pdf extension
---

# PDF pass-through or PDF/A upgrade

Handles a source that is already a PDF: either it is copied through unchanged, or it is reloaded and re-saved to apply PDF/A-1b conformance. This operation is also the destination of the `txt` → `pdf` resubmission in [Convert a source document to PDF](convert-source-document-to-pdf.md).

| Field | Value |
| --- | --- |
| **Operation ID** | OP-SFC-009 |
| **Trigger** | Called by [Execute a single conversion (converter template)](execute-single-conversion.md) via `PdfConverter.ConvertItem`, dispatched from [Convert a source document to PDF](convert-source-document-to-pdf.md) for `pdf` (including the recursive `txt`→`pdf` resubmission) |
| **Inputs** | Source `Stream`, `ConvertRequest` |
| **Outputs** | PDF `byte[]`, or `null` |
| **Primary components** | `PdfConverter.ConvertItem` |
| **Entry point** | `PdfApi.SyncFusionCore\Convert\PdfConverter.cs` |

## Steps

1. When `request.Options.IsPdfa`: load the stream as a `PdfLoadedDocument`, set
   `Conformance = Pdf_A1B`, save to a `MemoryStream`, and return the bytes ([BR-SFC-020](../business-rules.md#br-sfc-020-pdf%2Fa-applied-via-reload-and-resave)).
   - The loaded document is not disposed on this path.*
2. Otherwise, when `request.FileExtension == "pdf"`: copy the stream verbatim into a `MemoryStream`
   and return the bytes unchanged ([BR-SFC-021](../business-rules.md#br-sfc-021-plain-pdf-returned-unchanged)).
3. If neither branch applies, return `null`.
   - This makes [Execute a single conversion (converter template)](execute-single-conversion.md)
     step 6 mark the result `Failed` ([BR-SFC-007](../business-rules.md#br-sfc-007-conversion-success-requires-non-null-document)).

## Process flow

The following diagram visualizes this operation's control flow.

```mermaid
flowchart TD
	Start(["ConvertItem called<br>with stream, request"]) --> PdfaCheck{"Options.IsPdfa?"}
	PdfaCheck -->|Yes| LoadDoc["Load as PdfLoadedDocument,<br>set Conformance = Pdf_A1B"]
	LoadDoc --> SaveA[Save to MemoryStream]
	SaveA --> ReturnA([Return upgraded bytes])
	PdfaCheck -->|No| ExtCheck{"FileExtension<br>== pdf?"}
	ExtCheck -->|Yes| CopyThrough["Copy stream verbatim<br>to MemoryStream"]
	CopyThrough --> ReturnB([Return unchanged bytes])
	ExtCheck -->|No| ReturnNull([Return null])
```

## Failure and edge-case behavior

- Returning `null` when neither branch applies is treated identically to any other conversion
  failure by [Execute a single conversion (converter template)](execute-single-conversion.md).
- Any Syncfusion conversion failure surfaces as an exception, which is caught by
  [Execute a single conversion (converter template)](execute-single-conversion.md) and turned into a failed `PdfResult` rather than propagated here.

## Related documentation
- [Operations and processes](../operations-processes.md)
- [Business rules](../business-rules.md)

> **Note:** Statements marked with * were inferred from code structure, naming conventions, or
> contextual evidence where direct confirmation was not available in source artifacts.

## Sources
- `PdfApi.SyncFusionCore\Convert\PdfConverter.cs`
